FUNCTION
list.repeat
Repeat this list n times.
Examples:
[1, 2, 3].repeat(3)returns[1, 2, 3, 1, 2, 3, 1, 2, 3]list<T>().repeat(3)returns[](for any typeT)[3].repeat(0)returns[]
Parameters
- n — the number of times to repeat this list
Returns
a new list with the elements from this list repeated n times
Throws
exception— when: -nis negative -nis greater than(2^31)-1- the resulting list has size greater than(2^31)-1
Since
0.11.0
© 2026 Chromia